In NAND type flash memories (each of which will be referred to as a NAND memory, hereinafter) of a planar type, scaling has been advancing to increase the storage density. However, scaling in planar directions has been nearly reaching the limit. In light of this, there is proposed a NAND memory of a three-dimensional type, in which memory elements are arranged in a three-dimensional state. In NAND memories of a three-dimensional type, the memory cell arrangement region has a structure in which a plurality of thin metal films are stacked in an in-plane direction of a semiconductor wafer, but the peripheral circuit arrangement region has a structure in which these thin metal films are not present. In other words, a NAND memory of a three-dimensional type has cross sectional structures different from each other between the memory cell arrangement region and the peripheral circuit arrangement region. Consequently, the film stress generated by the memory cell arrangement region where the thin metal films are concentrated becomes dominant, and the semiconductor wafer is thereby warped in a specific direction depending on the arrangement direction of the layout of the thin metal films.